package com.xhiji.test.singletion;

/**
 * 静态内部类方式
 */
public class Singletion2 {

    private static class SingletionHolder{
        private static final Singletion2 instance = new Singletion2();
    }

    private Singletion2(){}

    public Singletion2 getInstance(){
        return SingletionHolder.instance;
    }
}
